package main

import (
	"fmt"

	"github.com/gin-gonic/gin"
)

func countPrimes(n int) int {
	var temp []bool = make([]bool, n)
	result := 0

	for i := 2; i < n; i++ {
		if !temp[i] {
			result++
			for j := i * 2; j < n; j += i {
				temp[j] = true
			}

		}
	}
	return result
}

func main() {
	fmt.Println(countPrimes(12))
	e := gin.Default()
	e.GET("/", func(c *gin.Context) {
		c.JSON(200, map[string]string{"helo": "world" + string(rune(countPrimes(12)))})
	})

	e.Run()
}
